using McpApi.Models;

namespace McpApi.Services
{
    /// <summary>
    /// MCP工具注册表接口
    /// </summary>
    public interface IToolRegistry
    {
        /// <summary>
        /// 获取所有可用工具
        /// </summary>
        Task<IEnumerable<Tool>> GetToolsAsync();

        /// <summary>
        /// 调用指定工具
        /// </summary>
        Task<MESToolResult> CallToolAsync(string toolName, Dictionary<string, object> arguments);

        /// <summary>
        /// 注册工具
        /// </summary>
        Task RegisterToolAsync(Tool tool, Func<Dictionary<string, object>, Task<MESToolResult>> handler);

        /// <summary>
        /// 获取工具数量
        /// </summary>
        int GetToolCount();
    }
}
